Fix xenbus userspace device transaction tracking.
authorcl349@firebug.cl.cam.ac.uk <cl349@firebug.cl.cam.ac.uk>
Thu, 4 May 2006 09:25:27 +0000 (10:25 +0100)
committercl349@firebug.cl.cam.ac.uk <cl349@firebug.cl.cam.ac.uk>
Thu, 4 May 2006 09:25:27 +0000 (10:25 +0100)
If a transaction end command fails, the semaphore which keeps track
of whether we're in a transaction or not was not getting updated.

Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
linux-2.6-xen-sparse/drivers/xen/xenbus/xenbus_xs.c

index 2cb2e97a879dbf5e8f5817376f870f4bb7acefa7..efafafdcb6cfa37af2a80691e6f5d2aeae450dac 100644 (file)
@@ -183,7 +183,7 @@ void *xenbus_dev_request_and_reply(struct xsd_sockmsg *msg)
 
        mutex_unlock(&xs_state.request_mutex);
 
-       if ((msg->type == XS_TRANSACTION_END) ||
+       if ((req_msg.type == XS_TRANSACTION_END) ||
            ((req_msg.type == XS_TRANSACTION_START) &&
             (msg->type == XS_ERROR)))
                up_read(&xs_state.suspend_mutex);